/*

This file is part of Ext JS 4

Copyright (c) 2011 Sencha Inc

Contact:  http://www.sencha.com/contact

GNU General Public License Usage
This file may be used under the terms of the GNU General Public License version 3.0 as published by the Free Software Foundation and appearing in the file LICENSE included in the packaging of this file.  Please review the following information to ensure the GNU General Public License version 3.0 requirements will be met: http://www.gnu.org/copyleft/gpl.html.

If you are unsure which license is appropriate for your use, please contact the sales department at http://www.sencha.com/contact.

*/
/**
 * Traditional Chinese translation
 * By hata1234
 * 09 April 2007
 */
Ext.onReady(function(){
    if(Ext.Updater) {
        Ext.Updater.defaults.indicatorText = '<div class="loading-indicator">è®€å�–ä¸­...</div>';
    }

    if(Ext.view.View){
        Ext.view.View.prototype.emptyText = "";
    }

    if(Ext.grid.Panel){
        Ext.grid.Panel.prototype.ddText = "é�¸æ“‡äº† {0} è¡Œ";
    }

    if(Ext.TabPanelItem){
        Ext.TabPanelItem.prototype.closeText = "é—œé–‰æ­¤æ¨™ç±¤";
    }

    if(Ext.form.field.Base){
        Ext.form.field.Base.prototype.invalidText = "æ•¸å€¼ä¸�ç¬¦å�ˆæ¬„ä½�è¦�å®š";
    }

    if(Ext.LoadMask){
        Ext.LoadMask.prototype.msg = "è®€å�–ä¸­...";
    }
    
    if (Ext.Date){
        Ext.Date.monthNames = [
        "ä¸€æœˆ",
        "äºŒæœˆ",
        "ä¸‰æœˆ",
        "å››æœˆ",
        "äº”æœˆ",
        "å…­æœˆ",
        "ä¸ƒæœˆ",
        "å…«æœˆ",
        "ä¹�æœˆ",
        "å��æœˆ",
        "å��ä¸€æœˆ",
        "å��äºŒæœˆ"
        ];

        Ext.Date.dayNames = [
        "æ—¥",
        "ä¸€",
        "äºŒ",
        "ä¸‰",
        "å››",
        "äº”",
        "å…­"
        ];
    }
    
    if(Ext.MessageBox){
        Ext.MessageBox.buttonText = {
            ok : "ç¢ºå®š",
            cancel : "å�–æ¶ˆ",
            yes : "æ˜¯",
            no : "å�¦"
        };
    }

    if(Ext.util.Format){
        Ext.apply(Ext.util.Format, {
            thousandSeparator: '.',
            decimalSeparator: ',',
            currencySign: '\u00a5',  // Chinese Yuan
            dateFormat: 'Y/m/d'
        });
    }

    if(Ext.picker.Date){
        Ext.apply(Ext.picker.Date.prototype, {
            todayText         : "ä»Šå¤©",
            minText           : "æ—¥æœŸå¿…é ˆå¤§æ–¼æœ€å°�å®¹è¨±æ—¥æœŸ",
            maxText           : "æ—¥æœŸå¿…é ˆå°�æ–¼æœ€å¤§å®¹è¨±æ—¥æœŸ",
            disabledDaysText  : "",
            disabledDatesText : "",
            monthNames        : Ext.Date.monthNames,
            dayNames          : Ext.Date.dayNames,
            nextText          : "ä¸‹å€‹æœˆ (Ctrl+å�³æ–¹å�‘é�µ)",
            prevText          : "ä¸Šå€‹æœˆ (Ctrl+å·¦æ–¹å�‘é�µ)",
            monthYearText     : "é�¸æ“‡æœˆä»½ (Ctrl+ä¸Š/ä¸‹æ–¹å�‘é�µé�¸æ“‡å¹´ä»½)",
            todayTip          : "{0} (ç©ºç™½é�µ)",
            format            : "y/m/d"
        });
    }

    if(Ext.picker.Month) {
        Ext.apply(Ext.picker.Month.prototype, {
            okText            : "ç¡®å®š",
            cancelText        : "å�–æ¶ˆ"
        });
    }

    if(Ext.toolbar.Paging){
        Ext.apply(Ext.PagingToolbar.prototype, {
            beforePageText : "ç¬¬",
            afterPageText  : "é �ï¼Œå…±{0}é �",
            firstText      : "ç¬¬ä¸€é �",
            prevText       : "ä¸Šä¸€é �",
            nextText       : "ä¸‹ä¸€é �",
            lastText       : "æœ€å¾Œé �",
            refreshText    : "é‡�æ–°æ•´ç�†",
            displayMsg     : "é¡¯ç¤º{0} - {1}ç­†,å…±{2}ç­†",
            emptyMsg       : 'æ²’æœ‰ä»»ä½•è³‡æ–™'
        });
    }

    if(Ext.form.field.Text){
        Ext.apply(Ext.form.field.Text.prototype, {
            minLengthText : "æ­¤æ¬„ä½�æœ€å°‘è¦�è¼¸å…¥ {0} å€‹å­—",
            maxLengthText : "æ­¤æ¬„ä½�æœ€å¤šè¼¸å…¥ {0} å€‹å­—",
            blankText     : "æ­¤æ¬„ä½�ç‚ºå¿…å¡«",
            regexText     : "",
            emptyText     : null
        });
    }

    if(Ext.form.field.Number){
        Ext.apply(Ext.form.field.Number.prototype, {
            minText : "æ­¤æ¬„ä½�ä¹‹æ•¸å€¼å¿…é ˆå¤§æ–¼ {0}",
            maxText : "æ­¤æ¬„ä½�ä¹‹æ•¸å€¼å¿…é ˆå°�æ–¼ {0}",
            nanText : "{0} ä¸�æ˜¯å�ˆæ³•çš„æ•¸å­—"
        });
    }

    if(Ext.form.field.Date){
        Ext.apply(Ext.form.field.Date.prototype, {
            disabledDaysText  : "ç„¡æ³•ä½¿ç”¨",
            disabledDatesText : "ç„¡æ³•ä½¿ç”¨",
            minText           : "æ­¤æ¬„ä½�ä¹‹æ—¥æœŸå¿…é ˆåœ¨ {0} ä¹‹å¾Œ",
            maxText           : "æ­¤æ¬„ä½�ä¹‹æ—¥æœŸå¿…é ˆåœ¨ {0} ä¹‹å‰�",
            invalidText       : "{0} ä¸�æ˜¯æ­£ç¢ºçš„æ—¥æœŸæ ¼å¼� - å¿…é ˆåƒ�æ˜¯ ã€Œ {1} ã€� é€™æ¨£çš„æ ¼å¼�",
            format            : "Y/m/d"
        });
    }

    if(Ext.form.field.ComboBox){
        Ext.apply(Ext.form.field.ComboBox.prototype, {
            loadingText       : "è®€å�–ä¸­ ...",
            valueNotFoundText : undefined
        });
    }

    if(Ext.form.field.VTypes){
        Ext.apply(Ext.form.field.VTypes, {
            emailText    : 'æ­¤æ¬„ä½�å¿…é ˆè¼¸å…¥åƒ� "user@example.com" ä¹‹E-Mailæ ¼å¼�',
            urlText      : 'æ­¤æ¬„ä½�å¿…é ˆè¼¸å…¥åƒ� "http:/'+'/www.example.com" ä¹‹ç¶²å�€æ ¼å¼�',
            alphaText    : 'æ­¤æ¬„ä½�åƒ…èƒ½è¼¸å…¥å�Šå½¢è‹±æ–‡å­—æ¯�å�Šåº•ç·š( _ )ç¬¦è™Ÿ',
            alphanumText : 'æ­¤æ¬„ä½�åƒ…èƒ½è¼¸å…¥å�Šå½¢è‹±æ–‡å­—æ¯�ã€�æ•¸å­—å�Šåº•ç·š( _ )ç¬¦è™Ÿ'
        });
    }

    if(Ext.grid.header.Container){
        Ext.apply(Ext.grid.header.Container.prototype, {
            sortAscText  : "æ­£å�‘æŽ’åº�",
            sortDescText : "å��å�‘æŽ’åº�",
            lockText     : "éŽ–å®šæ¬„ä½�",
            unlockText   : "è§£é–‹æ¬„ä½�éŽ–å®š",
            columnsText  : "æ¬„ä½�"
        });
    }

    if(Ext.grid.PropertyColumnModel){
        Ext.apply(Ext.grid.PropertyColumnModel.prototype, {
            nameText   : "å��ç¨±",
            valueText  : "æ•¸å€¼",
            dateFormat : "Y/m/d"
        });
    }

    if(Ext.layout.BorderLayout && Ext.layout.BorderLayout.SplitRegion){
        Ext.apply(Ext.layout.BorderLayout.SplitRegion.prototype, {
            splitTip            : "æ‹–æ›³ç¸®æ”¾å¤§å°�.",
            collapsibleSplitTip : "æ‹–æ›³ç¸®æ”¾å¤§å°�. æ»‘é¼ é›™æ“Šéš±è—�."
        });
    }
});
